let myVue = new Vue({
    el:"#main",
    data:{
        pageInfo:{},
    },
    methods: {
        selectPage: function (pageNum, pageSize) {
            axios({
                url: `account/selectPage/${pageNum}/${pageSize}`
            }).then(response => {
                this.pageInfo = response.data.obj;
            });
        },
        toInsert:function () {
            window.location='html/account/account_add.html'
        },
        toDetail:function (id) {
            layer.obj = id; //绑定id到index窗口对象layer中
            layer.message = '';
            layer.open(
                {
                    type: 2, //iframe
                    title: '详情页面',
                    area: ['80%', '90%'],
                    content: 'account/toDetail'
                }
            )
        }
    },
    //初始化
    created:function () {
        this.selectPage(1,5);
    }
});